package com.androidx.p013lv.mine.model;

import androidx.lifecycle.MutableLiveData;
import androidx.lifecycle.ViewModel;
import com.androidx.p013lv.base.http.BaseRes;
import com.androidx.p013lv.base.http.HttpUtils;
import com.androidx.p013lv.base.http.UrlManager;
import com.androidx.p013lv.base.http.callback.HttpCallback;
import com.androidx.p013lv.mine.bean.CollectVideoBean;

/* renamed from: com.androidx.lv.mine.model.MineBuyVideoModel */
public class MineBuyVideoModel extends ViewModel {
    private MutableLiveData<BaseRes<CollectVideoBean>> buyData;

    public MutableLiveData<BaseRes<CollectVideoBean>> data() {
        if (this.buyData == null) {
            this.buyData = new MutableLiveData<>();
        }
        return this.buyData;
    }

    public void getBuyVideoList(int i) {
        HttpUtils.getInsatance().get(UrlManager.getInsatance().userBuyVideoData(i, false), new HttpCallback<BaseRes<CollectVideoBean>>("userBuyVideoData") {
            /* class com.androidx.p013lv.mine.model.MineBuyVideoModel.C13541 */

            public void onLvSuccess(BaseRes<CollectVideoBean> baseRes) {
                MineBuyVideoModel.this.buyData.setValue(baseRes);
            }
        });
    }

    public void cancelHttp() {
        HttpUtils.getInsatance().cancelTag("userBuyVideoData");
    }
}
